#pragma once

#include <string>
#include <vector>

struct FileInfo
{
	std::string		m_relativePath;
	std::string	m_absolutePath;
};

/// Scan content of given directory looking for specific files
extern void ScanDir( const std::string& absolutePath, const std::string& relativePath, const char* pattern, std::vector< FileInfo >& outFiles );

/// Get file modification timestamp
#ifdef WIN32
typedef unsigned long long FileTime;
#else
typedef time_t FileTime;
#endif
extern bool GetFileModificationTime( const std::string& path, FileTime& outTimeCode );

/// Load content of file into a string
extern std::string LoadStringFromFile( const std::string& path );

/// Get last occurence of given string
extern const char* LastStr( const char* txt, const char* pat );

/// Shorten the relative path (base it on src\\ or include\\)
extern std::string ShortRelativePath( const std::string& path );

/// Get base path of file (path before src\\ or include\\)
extern std::string BasePath( const std::string& path );